package hxs.events.flash.display;
import hxs.extras.FlashEventsStore;
import hxs.extras.FlashSignal;
import hxs.events.flash.events.EventDispatcherEvents;
/**
 * ...
 * @author Tony Polinelli
 */
import flash.display.DisplayObject;
import flash.events.Event;

class DisplayObjectEvents extends EventDispatcherEvents
{
	public function new(target:DisplayObject) 
	{
		super(target);
	}
	
	public static function getEvents(target:DisplayObject):DisplayObjectEvents
	{
		return cast FlashEventsStore.getEvents(target);
	}
	
	/**/

	public var added(getAdded, never):FlashSignal<Event>;
	private function getAdded():FlashSignal<Event>
	{
		return cast getNativeSignal(Event.ADDED);
	}

	public var addedToStage(getAddedToStage, never):FlashSignal<Event>;
	private function getAddedToStage():FlashSignal<Event>
	{
		return cast getNativeSignal(Event.ADDED_TO_STAGE);
	}

	public var enterFrame(getEnterFrame, never):FlashSignal<Event>;
	private function getEnterFrame():FlashSignal<Event>
	{
		return cast getNativeSignal(Event.ENTER_FRAME);
	}

	#if flash10
	public var exitFrame(getExitFrame, never):FlashSignal<Event>;
	private function getExitFrame():FlashSignal<Event>
	{
		return cast getNativeSignal(Event.EXIT_FRAME);
	}

	public var frameConstructed(getFrameConstructed, never):FlashSignal<Event>;
	private function getFrameConstructed():FlashSignal<Event>
	{
		return cast getNativeSignal(Event.FRAME_CONSTRUCTED);
	}
	#end
	
	public var removed(getRemoved, never):FlashSignal<Event>;
	private function getRemoved():FlashSignal<Event>
	{
		return cast getNativeSignal(Event.REMOVED);
	}

	public var removedFromStage(getRemovedFromStage, never):FlashSignal<Event>;
	private function getRemovedFromStage():FlashSignal<Event>
	{
		return cast getNativeSignal(Event.REMOVED_FROM_STAGE);
	}

	public var render(getRender, never):FlashSignal<Event>;
	private function getRender():FlashSignal<Event>
	{
		return cast getNativeSignal(Event.RENDER);
	}
	
}